/* Variables de colores mejorados para legibilidad */
:root {
    --rosa: #fcaed5;
    --rosa-oscuro: #c2437e;
    --verde-manzana: #c5ed85;
    --azul-cielo: #b1daea;
    --naranja: #FFC983;
    --blanco: #FFFFFF;
    --negro: #4a3f4d;
    --rosa-claro: #ffe3f1;
    
    /* Colores adicionales para mejor legibilidad */
    --verde-suave: #e8f5e8;
    --texto-oscuro: #4a3f4d;
    --azul-claro: #e3f2fd;
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    font-family: 'Bubblegum Sans', sans-serif;
}

body {
    margin: 0;
    padding: 20px;
    box-sizing: border-box;
    background-color:white;
    color: var(--texto-oscuro);
}

header {
    background: linear-gradient(to bottom, #ffe3f1, #FFFFFF 75%);
    color: var(--rosa-oscuro);
    padding: 1.5rem 1rem;
    border-radius: 16px;
}

h1 {
    text-align: center;
    color: var(--rosa);
    font-weight: bolder; 
    font-size: 2.5rem;
}

.navegacion {
    background-color: #FFFFFF;
    border: 1px solid var(--verde-manzana);
    width: 100%;
    top: 0;
    z-index: 1000;
    text-align: center;
    display: flex;
    justify-content: space-around;
    padding: 0.5rem;
    border-radius: 15px;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.10);
}

.navegacion a {
    text-decoration: none;
    color: #4a7c2c;
    background: none;
    padding: 0.5rem 1rem;
    font-weight: 500;
    border-radius: 20px;
    transition: all .3s ease;
}

.navegacion a:hover {
    color: var(--rosa-oscuro);
    background-color: var(--rosa-claro);
}

.banner {
    margin-bottom: 2rem;
    border-radius: 25px;
    text-align: center;
}

.banner img {
    border-radius: 25px;
    padding: 5px;
    max-width: 100%;
    width: 850px;
    display: block;
    margin: auto;
    box-shadow: 0 8px 18px rgba(0,0,0,.15);
}

section {
    text-align: center;
}

.historia-pinatas {
    padding: 3rem 0;
    background: transparent;
    color: var(--texto-oscuro);
}

.historia-pinatas > h2 {
    margin-bottom: .8rem;
    text-align: center;
    color: var(--rosa-oscuro);
}

.intro-historia {
    max-width: 900px;
    margin: 0 auto 2rem;
    text-align: center;
    line-height: 1.8;
    font-size: 1.05rem;
}

.contenedor-servicios {
    display: flex;
    flex-wrap: wrap;
    gap: 2rem;
    justify-content: center;
    align-items: flex-start;
    max-width: 1100px;
    margin: 0 auto;
}

.columnas {
    flex: 1 1 300px;
    max-width: 340px;
    background: var(--blanco);
    border-radius: 25px;
    padding: 1.8rem;
    min-height: unset;
    box-shadow: 0 8px 18px rgba(0, 0, 0, 0.08);
    transition: transform .3s;
    box-sizing: border-box;
}

.columnas:hover {
    transform: translateY(-6px);
}

.tarjeta-origen {
    border-top: 6px solid var(--rosa);
}

.tarjeta-simbolismo {
    border-top: 6px solid #ffd23f;
}

.tarjeta-hoy {
    border-top: 6px solid #dfb6ff;
}

.columnas h2 {
    margin: 0;
    font-size: 1.5rem;
    color: var(--rosa);
    text-align: center;
}

.subtitulo-card {
    margin: 0.4rem 0 1rem;
    padding: 0;
    text-align: center;
    font-size: 0.95rem;
    font-style: italic;
    color: var(--verde-manzana);
    line-height: 1.5;
}

.iconos {
    width: 75px;
    height: 75px;
    display: block;
    margin: 0 auto 1.2rem;
    border-radius: 50%;
    object-fit: cover;
}

.columnas p {
    font-size: 1rem;
    line-height: 1.7;
    color: #555;
    text-align: left;
}

.lista-simbolos {
    list-style: none;
    padding: 0;
    margin: 1rem 0;
}

.lista-simbolos > li {
    padding: 0.4rem 0;
    color: #555;
}

.lista-simbolos ol {
    margin-left: 1.2rem;
    margin-top: 0.5rem;
}

.lista-simbolos li em {
    color: #8b46cd; /* Estilo alegre para los nombres de los pecados */
    font-weight: bold;
}

/* ==========================================================================
   ESTILOS PARA EL TEXTO EXPANDIBLE (JAVASCRIPT / INTERACTIVIDAD)
   ========================================================================== */

/* Botones interactivos de "Descubrir más" y "Mostrar menos" */
.btn-expandir, .btn-contraer {
    display: block;
    color: var(--rosa);
    font-weight: bold;
    margin-top: 1rem;
    cursor: pointer;
    font-size: 0.95rem;
    text-align: center;
    transition: transform 0.2s ease;
}

.btn-expandir:hover, .btn-contraer:hover {
    transform: scale(1.03);
    color: var(--naranja); /* Cambia al color interactivo de tus redes sociales */
}

/* Clase utilitaria para esconder el bloque de texto completo al cargar la página */
.oculto {
    display: none;
}

/* ================================================= */
/* AJUSTE: Galería estable y responsiva */
/* ================================================= */
.gallery {
    columns: 4;
    column-gap: 1.2rem;
    max-width: 1100px;
    margin: 2rem auto;
}

.gallery img {
    margin: 0;
    border-radius: 20px;
}

.card {
    display: inline-block;
    width: 100%;
    margin-bottom: 1.5rem;
    break-inside: avoid;
    background:
        linear-gradient(var(--blanco), var(--blanco)) padding-box,
        linear-gradient(135deg, #ff8ec6, #a8d95f) border-box;
    border: 3px solid transparent;
    border-radius: 25px;
    box-shadow: 0 6px 16px rgba(0,0,0,.10);
    overflow: hidden;
    transition: transform .4s ease, box-shadow .4s ease;
}

.card:hover {
    transform: translateY(-5px);
    box-shadow: 0 10px 20px rgba(0, 0, 0, 0.15);
}

.thumbnail {
    width: 100%; 
    height: auto;
    display: block;
    cursor: pointer;
    transition: transform .5s ease;
}

.card:hover .thumbnail {
    transform: translateY(-6px) rotate(1deg);
}

.thumbnail:hover {
    border-color: #f817a9;
}

/* ================================================= */
/* AJUSTE: Estilos para el botón y las imágenes de "Ver Más Piñatas" */
/* ================================================= */

#contenedorPignatas {
    display: flex;
    flex-wrap: wrap; 
    justify-content: center; 
    gap: 15px; 
    padding: 20px 0;
}

#contenedorPignatas img {
    max-width: 300px; 
    height: auto; 
    border-radius: 25px;
    padding: 5px;
    border: 1px solid var(--verde-manzana);
    background-color: var(--verde-suave); 
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
}

#masPignatas {
    background-color: var(--naranja);
    color: var(--blanco);
    border: none;
    padding: 10px 20px;
    margin: 20px auto;
    cursor: pointer;
    border-radius: 10px;
    font-size: 1rem;
    display: block; 
    width: fit-content; 
    text-transform: uppercase;
    font-weight: bold;
}

#masPignatas:hover {
    background-color: var(--naranja);
}


/* ================================================= */
/* Estilos para el Modal y navegación */
/* ================================================= */
.modal {
    display: none;
    position: fixed;
    z-index: 1001; 
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
    overflow: auto;
    background-color: rgba(0, 0, 0, 0.9); 
}

.modal-content {
    display: flex;
    justify-content: center;
    align-items: center;
    width: 100%;
    height: 100%;
    background-color: transparent; 
}

.modal-image {
    max-width: 90%;
    max-height: 90%;
    display: block;
    margin: auto;
}

.close, .prev, .next {
    position: absolute;
    color: var(--blanco);
    font-size: 40px;
    font-weight: bold;
    cursor: pointer;
    z-index: 1002;
    background-color: transparent;
    padding: 10px;
}

.close {
    right: 35px;
    top: 15px;
}

.prev {
    top: 50%;
    left: 15px;
    transform: translateY(-50%);
}

.next {
    top: 50%;
    right: 15px;
    transform: translateY(-50%);
}

/* ============================
   PROCESO DE ELABORACIÓN
============================ */

.proceso-creacion {
    max-width: 1200px;
    margin: 5rem auto;
    padding: 0 2rem;
}

.proceso-creacion h2 {
    text-align: center;
    color: var(--rosa);
    font-size: 2rem;
    margin-bottom: 1rem;
}

.presentacion-proceso {
    max-width: 800px;
    margin: 0 auto 2.5rem;
    text-align: center;
    line-height: 1.8;
    font-size: 1.1rem;
    color: #555;
}

.portada-proceso {
    text-align: center;
    margin-bottom: 2rem;
}

.frase-final{
    display: inline-block;
    max-width: 300px;
    margin-top: .8rem;
    padding: .6rem 1.2rem;
    border-radius: 25px;
    background: linear-gradient(90deg,
        rgba(255,111,181,.10),
        rgba(159,211,86,.10)
    );
    color: #666;
    font-style: italic;
    font-weight: 600;
}

.pinata-final {
    display: block;
    width: 100%;
    max-width: 360px;
    margin: 0 auto;
    border-radius: 25px;
    border: 4px solid var(--verde-manzana);
    box-shadow: 0 8px 20px rgba(0,0,0,.15);
}

.pasos{
    display:flex;
    flex-direction:column;
    gap:2.5rem;
}

.paso{
    background: var(--azul-claro);
    border-radius:25px;
    padding:2rem;
    box-shadow:0 8px 18px rgba(0,0,0,.08);
    border-left: 6px solid var(--verde-manzana);
    transition: .3s;
}

.paso:hover {
    transform: translateY(-4px);
    box-shadow: 0 12px 24px rgba(0, 0, 0, 0.12);
}

.paso h3{
    color:var(--rosa);
    margin-bottom:1rem;
}

.paso p{
    color: #555;
    margin-bottom:1.5rem;
    line-height:1.8;
}

.paso:nth-child(odd) {
    border-left: 6px solid var(--rosa);
}

.paso:nth-child(even) {
    border-left: 6px solid var(--verde-manzana);
}

.imagenes-paso{
    display:flex;
    justify-content: center;
    gap:1rem;
    flex-wrap: wrap;
}

.imagenes-paso img{
    width:100%;
    max-width: 280px;
    max-height: 220px;
    object-fit:contain;
    background: white;
    padding: .5rem;
    border-radius:18px;
    border: 3px solid #f7d6e8;
    box-shadow:0 4px 10px rgba(0,0,0,.08);
    transition:.3s;
}

.imagenes-paso img:hover{
    transform:scale(1.03);
    border-color: var(--verde-manzana);
}

.frase-final-proceso {
    max-width: 850px;
    margin: 4rem auto 0;
    padding: 1.5rem 2rem;
    text-align: center;
    font-size: 1.2rem;
    font-style: italic;
    color: var(--rosa);
    background: linear-gradient(90deg, rgba(255,111,181,.08), rgba(159,211,86,.08));
    border-radius: 20px;
}

.container-input:nth-child(3),
.container-input:nth-child(4){
    grid-column: 1/3;
}

.container-input textarea {
    height: 10rem;
}

.despedida{
    text-align: center;
    padding: 60px 20px;
}

.contenedor-despedida {
    max-width: 650px;
    margin: 0 auto;
}

.despedida h2{
    color: var(--rosa);
    font-size: 2.2rem;
    margin-bottom: 20px;
}

.introduccion, .texto-contacto {
    font-size: 1.1rem;
    line-height: 1.6;
    margin-bottom: 25px;
}

.firma {
    font-style: italic;
    font-size: 1.15rem;
    background-color: #f7f3fb;
    padding: 15px;
    border-radius: 12px;
    margin-bottom: 40px;
}

.llamada-accion {
    font-size: 1.4rem;
    font-weight: bold;
    margin-bottom: 10px;
}

.redes-sociales {
    display: flex;
    justify-content: center;
    gap: 20px;
    margin-top: 25px;
}

.redes-sociales a{
    width:55px;
    height:55px;
    display:flex;
    align-items:center;
    justify-content:center;
    border-radius:50%;
    background:var(--rosa);
    color:white;
    text-decoration:none;
    transition:.3s;
}

.redes-sociales a:hover{
    background:var(--naranja);
    transform:translateY(-4px);
}

.redes-sociales i{
    font-size:1.4rem;
}

footer{
    margin-top:2rem;
    padding:1.2rem;
    text-align:center;
    border-top:1px solid rgba(0,0,0,.08);
    background: #a5f3fc;
}

footer p{
    margin:0;
    color:var(--texto-oscuro);
    font-size:.9rem;
}

/* ========== ESTILOS PARA TEXTO EXPANDIBLE ========== */

.texto-expandible {
    position: relative;
}

.texto-expandible .oculto {
    display: none;
}

.btn-expandir,
.btn-contraer {
    color: var(--rosa);
    cursor: pointer;
    font-weight: bold;
    text-decoration: none;
    display: block;
    text-align: center;
    margin-top: 1rem;
    margin-left: 0;
    transition: color 0.3s ease;
    background-color: transparent;
}

.btn-expandir:hover,
.btn-contraer:hover {
    color: var(--naranja);
}

.texto-resumen,
.texto-completo {
    background-color: transparent;
    line-height: 1.8;
    font-size: 1rem;
} 

#btnUp {
  position: fixed;
  bottom: 30px;
  right: 30px;
  padding: 10px 15px;
  font-size: 24px;
  background-color: var(--rosa);
  color: white;
  border: none;
  border-radius: 50%;
  cursor: pointer;
  display: none;
  box-shadow: 0 2px 5px rgba(0,0,0,0.3);
  transition: background-color 0.3s ease;
  z-index: 1000;
}

#btnUp:hover {
  background-color: var(--verde-manzana);
}

.presentacion {
    text-align: center;
    padding: 2rem 1rem;
    margin-bottom: 1rem;
}

.presentacion h1 {
    font-size: clamp(2.5rem, 5vw, 4rem);
    color: #f817a9;
    margin-bottom: 1rem;
}

.subtitulo {
    max-width: 800px;
    margin: 0 auto;
    padding: 0 1rem;
    font-size: 1.2rem;
    color: var(--texto-oscuro);
    line-height: 1.6;
}

.btn-principal {
    display: inline-block;
    margin-top: 1.5rem;
    padding: 12px 30px;
    background-color: var(--naranja);
    color: white;
    text-decoration: none;
    border-radius: 25px;
    font-weight: bold;
    transition: all 0.3s ease;
}

.btn-principal:hover {
    background-color: darkorange;
    transform: translateY(-2px);
}

.intro-galeria {
    max-width: 700px;
    margin: 1rem auto 2rem auto;
    padding: 0 1rem;
    color: var(--texto-oscuro);
    line-height: 1.6;
}

/* ENCARGOS */

.encargos{
    max-width: 1200px;
    margin: 2rem auto;
    padding: 0 2rem;
}

.encargos h2{
    text-align: center;
    color: var(--rosa);
    font-size: 2rem;
    margin-bottom: 1rem;
}

.intro-encargos{
    max-width: 750px;
    margin: 0 auto 3rem;
    text-align: center;
    line-height: 1.8;
    color: #555;
    font-size: 1.05rem;
}

.pasos-pedido{
    display:grid;
    grid-template-columns:repeat(auto-fit,minmax(240px,1fr));
    gap:1.8rem;
}

.paso-pedido{
    position:relative;
    background:#fff;
    padding:2.5rem 1.5rem 1.8rem;
    border-radius:25px;
    text-align:center;
    box-shadow:0 8px 18px rgba(0,0,0,.08);
    transition:.35s;
    overflow:hidden;
}

.paso-pedido:nth-child(1){
    border-top:6px solid #ff6fb5;
}

.paso-pedido:nth-child(2){
    border-top:6px solid #5ec8f8;
}

.paso-pedido:nth-child(3){
    border-top:6px solid #ffd23f;
}

.paso-pedido:nth-child(4){
    border-top:6px solid #9fd356;
}

.paso-pedido:hover{
    transform:translateY(-8px);
    box-shadow:0 14px 25px rgba(0,0,0,.15);
}

.numero{
    width:55px;
    height:55px;
    margin:0 auto 1rem;
    border-radius:50%;
    display:flex;
    justify-content:center;
    align-items:center;
    font-size:1.4rem;
    font-weight:bold;
    color:white;
    background:linear-gradient(
        135deg,
        var(--rosa),
        var(--verde-manzana)
    );
    box-shadow:0 5px 12px rgba(0,0,0,.15);
}

.paso-pedido h3{
    color:var(--rosa);
    margin-bottom:.8rem;
    font-size:1.2rem;
}

.paso-pedido p{
    color:#555;
    line-height:1.7;
}

/* ==========================================================================
   ESTILOS UNIFICADOS PARA DISPOSITIVOS MÓVILES (Pantallas de 900px o menos)
   ========================================================================== */
@media (max-width: 900px) {
    /* --- Galería (Pinterest) --- */
    .gallery {
        columns: 2;
    }
}

@media (max-width: 768px) {

    /* 1. SECCIÓN: HISTORIA DE LAS PIÑATAS (Tu nuevo Carrusel Horizontal) */
    .contenedor-servicios {
        flex-wrap: nowrap !important;
        overflow-x: auto;
        justify-content: flex-start;
        padding: 10px 20px 25px 20px;
        scroll-snap-type: x mandatory;
        -webkit-overflow-scrolling: touch;
        gap: 1.5rem;
    }

    .contenedor-servicios::-webkit-scrollbar {
        display: none; /* Esconde la barra de scroll para que se vea limpio */
    }

    .columnas {
        flex: 0 0 290px;
        max-width: 290px;
        scroll-snap-align: center;
        box-shadow: 0 6px 15px rgba(0, 0, 0, 0.06);
    }

    .historia-pinatas > h2 {
        font-size: 1.6rem;
    }

    .intro-historia {
        font-size: 0.95rem;
        padding: 0 1rem;
    }


    /* 2. SECCIÓN: PASOS DEL PEDIDO */
    .pasos-pedido {
        grid-template-columns: 1fr;
        gap: 1.5rem;
    }


    /* 3. SECCIÓN: PROCESO DE CREACIÓN / FRASE FINAL */
    .proceso-creacion {
        padding: 0 1rem;
    }

    .paso {
        padding: 1.5rem;
    }

    .imagenes-paso {
        flex-direction: column;
        align-items: center;
        gap: 1rem;
    }


    /* 4. SECCIÓN: DESPEDIDA Y REDES SOCIALES */
    .despedida h2 {
        font-size: 1.5rem;
        padding: 0 10px;
    }

    .introduccion, .texto-contacto {
        font-size: 1rem;
        padding: 0 10px;
    }

    .redes-sociales {
        gap: 15px;
    }
}

@media (max-width: 600px) {
    /* --- Galería extrema en pantallas muy pequeñas --- */
    .gallery {
        columns: 1;
    }
    
    /* Pequeño ajuste para tarjetas en móviles muy estrechos */
    .columnas {
        flex: 0 0 260px;
        max-width: 260px;
    }
}